package com.bite.book.model;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User:DELL
 * Date:2025-06-03
 * Time:19:03
 */
@Data
public class PageRequest {
    private Integer pageNum =1;
    private Integer pageSize = 10;//limit
    private Integer offset;//需要计算，所以要进行定义

    public Integer getOffset() {
        return (pageNum-1)*pageSize;
    }
}
